package com.example.zhu.Mapper;

import com.example.zhu.dto.OrderProject;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper

public interface OrderProjectMapper {
    @Insert("insert into order_project (order_id,name,amount,count,total_prices,nickname,employee_type) VALUES (#{orderId},#{name},#{amount},#{count},#{totalPrices},#{nickname},#{employeeType})")
    void insert(OrderProject orderProject);

    @Select("select * from order_project where order_id=#{orderId} ")
    List<OrderProject> selectList(String orderId);
    @Delete("delete from order_project where order_id=#{id}")
    void deleteByOrderId(String id);
}
